<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.14"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>BabyOS: b_xm128.h Source File</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="2.png"/></td>
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">BabyOS
   &#160;<span id="projectnumber">V1.1.0</span>
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.14 -->
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
  initMenu('',false,false,'search.php','Search');
});
/* @license-end */</script>
<div id="main-nav"></div>
<div id="nav-path" class="navpath">
  <ul>
<li class="navelem"><a class="el" href="dir_b9223522bb56aee4ab59f7ba381d2163.html">bos</a></li><li class="navelem"><a class="el" href="dir_f2a2cc749b6bfcea90db6730434b0bd6.html">core</a></li><li class="navelem"><a class="el" href="dir_37b66dfbfdffce01c33ebea49c49c2c3.html">inc</a></li>  </ul>
</div>
</div><!-- top -->
<div class="header">
  <div class="headertitle">
<div class="title">b_xm128.h</div>  </div>
</div><!--header-->
<div class="contents">
<a href="b__xm128_8h.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;</div><div class="line"><a name="l00031"></a><span class="lineno">   31</span>&#160;<span class="preprocessor">#ifndef __B_XM128_H__</span></div><div class="line"><a name="l00032"></a><span class="lineno">   32</span>&#160;<span class="preprocessor">#define __B_XM128_H__</span></div><div class="line"><a name="l00033"></a><span class="lineno">   33</span>&#160;</div><div class="line"><a name="l00034"></a><span class="lineno">   34</span>&#160;<span class="preprocessor">#ifdef __cplusplus</span></div><div class="line"><a name="l00035"></a><span class="lineno">   35</span>&#160; <span class="keyword">extern</span> <span class="stringliteral">&quot;C&quot;</span> {</div><div class="line"><a name="l00036"></a><span class="lineno">   36</span>&#160;<span class="preprocessor">#endif</span></div><div class="line"><a name="l00037"></a><span class="lineno">   37</span>&#160;</div><div class="line"><a name="l00038"></a><span class="lineno">   38</span>&#160;<span class="comment">/*Includes ----------------------------------------------*/</span></div><div class="line"><a name="l00039"></a><span class="lineno">   39</span>&#160;<span class="preprocessor">#include &quot;<a class="code" href="b__config_8h.html">b_config.h</a>&quot;</span>  </div><div class="line"><a name="l00040"></a><span class="lineno">   40</span>&#160;<span class="preprocessor">#if _XMODEM128_ENABLE</span></div><div class="line"><a name="l00041"></a><span class="lineno">   41</span>&#160;</div><div class="line"><a name="l00057"></a><span class="lineno"><a class="line" href="structb_xmodem128_info__t.html">   57</a></span>&#160;<span class="keyword">typedef</span> <span class="keyword">struct</span></div><div class="line"><a name="l00058"></a><span class="lineno">   58</span>&#160;{</div><div class="line"><a name="l00059"></a><span class="lineno"><a class="line" href="structb_xmodem128_info__t.html#a87bdcb2d9de9c3eef834e0af26f2d5e3">   59</a></span>&#160;    uint8_t <a class="code" href="structb_xmodem128_info__t.html#a87bdcb2d9de9c3eef834e0af26f2d5e3">soh</a>;</div><div class="line"><a name="l00060"></a><span class="lineno"><a class="line" href="structb_xmodem128_info__t.html#af57eaec6f3dec6de717735725c9908a6">   60</a></span>&#160;    uint8_t <a class="code" href="structb_xmodem128_info__t.html#af57eaec6f3dec6de717735725c9908a6">number</a>;</div><div class="line"><a name="l00061"></a><span class="lineno"><a class="line" href="structb_xmodem128_info__t.html#ae817be61f4d69f01a76ff417b23f5a54">   61</a></span>&#160;    uint8_t <a class="code" href="structb_xmodem128_info__t.html#ae817be61f4d69f01a76ff417b23f5a54">xnumber</a>;</div><div class="line"><a name="l00062"></a><span class="lineno"><a class="line" href="structb_xmodem128_info__t.html#ab02bda4989472488cf520fd11c64a230">   62</a></span>&#160;    uint8_t dat[128];</div><div class="line"><a name="l00063"></a><span class="lineno"><a class="line" href="structb_xmodem128_info__t.html#ad47d5b159b4c95a163edac9d1b659751">   63</a></span>&#160;    uint8_t <a class="code" href="structb_xmodem128_info__t.html#ad47d5b159b4c95a163edac9d1b659751">check</a>;</div><div class="line"><a name="l00064"></a><span class="lineno">   64</span>&#160;}<a class="code" href="structb_xmodem128_info__t.html">bXmodem128Info_t</a>;</div><div class="line"><a name="l00065"></a><span class="lineno">   65</span>&#160;</div><div class="line"><a name="l00066"></a><span class="lineno">   66</span>&#160;</div><div class="line"><a name="l00067"></a><span class="lineno"><a class="line" href="group___x_m_o_d_e_m128___exported___types_definitions.html#ga1189ecafb71f5108788e9d2e7ac5e7f3">   67</a></span>&#160;<span class="keyword">typedef</span> void (*<a class="code" href="group___x_m_o_d_e_m128___exported___types_definitions.html#ga1189ecafb71f5108788e9d2e7ac5e7f3">pcb_t</a>)(uint8_t number, uint8_t *pbuf); </div><div class="line"><a name="l00068"></a><span class="lineno"><a class="line" href="group___x_m_o_d_e_m128___exported___types_definitions.html#gad6ebbc53d3047463033cb2b686f40d66">   68</a></span>&#160;<span class="keyword">typedef</span> void (*<a class="code" href="group___x_m_o_d_e_m128___exported___types_definitions.html#gad6ebbc53d3047463033cb2b686f40d66">psend</a>)(uint8_t cmd);</div><div class="line"><a name="l00069"></a><span class="lineno">   69</span>&#160;</div><div class="line"><a name="l00079"></a><span class="lineno"><a class="line" href="group___x_m_o_d_e_m128___exported___defines.html#gae18ee26e2806d368ce3917495a1eea35">   79</a></span>&#160;<span class="preprocessor">#define XMODEM128_SOH   0x01</span></div><div class="line"><a name="l00080"></a><span class="lineno"><a class="line" href="group___x_m_o_d_e_m128___exported___defines.html#ga58c8c951dd64e2ac3c55e9349161e83f">   80</a></span>&#160;<span class="preprocessor">#define XMODEM128_EOT   0x04</span></div><div class="line"><a name="l00081"></a><span class="lineno"><a class="line" href="group___x_m_o_d_e_m128___exported___defines.html#ga91186b9eed76278e60d5e89afe433170">   81</a></span>&#160;<span class="preprocessor">#define XMODEM128_ACK   0x06</span></div><div class="line"><a name="l00082"></a><span class="lineno"><a class="line" href="group___x_m_o_d_e_m128___exported___defines.html#gae9837d569d0f7301f6127cbd40565109">   82</a></span>&#160;<span class="preprocessor">#define XMODEM128_NAK   0x15</span></div><div class="line"><a name="l00083"></a><span class="lineno"><a class="line" href="group___x_m_o_d_e_m128___exported___defines.html#gacad3b5a81a9ab07952ae6352f4c1f5e8">   83</a></span>&#160;<span class="preprocessor">#define XMODEM128_CAN   0x18</span></div><div class="line"><a name="l00084"></a><span class="lineno">   84</span>&#160;</div><div class="line"><a name="l00112"></a><span class="lineno">  112</span>&#160;<span class="keywordtype">int</span> <a class="code" href="group___x_m_o_d_e_m128___exported___functions.html#ga75c122d0178d1616612a6d8e053ab3f4">bXmodem128Init</a>(<a class="code" href="group___x_m_o_d_e_m128___exported___types_definitions.html#ga1189ecafb71f5108788e9d2e7ac5e7f3">pcb_t</a> fcb, <a class="code" href="group___x_m_o_d_e_m128___exported___types_definitions.html#gad6ebbc53d3047463033cb2b686f40d66">psend</a> fs);</div><div class="line"><a name="l00113"></a><span class="lineno">  113</span>&#160;<span class="keywordtype">int</span> <a class="code" href="group___x_m_o_d_e_m128___exported___functions.html#ga22d59aa816e006be041442488ea8539c">bXmodem128Parse</a>(uint8_t *pbuf, uint8_t len);</div><div class="line"><a name="l00114"></a><span class="lineno">  114</span>&#160;<span class="keywordtype">int</span> <a class="code" href="group___x_m_o_d_e_m128___exported___functions.html#ga2999eae8ddb0eead2907b9e031e8f0cd">bXmodem128Start</a>(<span class="keywordtype">void</span>);</div><div class="line"><a name="l00115"></a><span class="lineno">  115</span>&#160;<span class="keywordtype">int</span> <a class="code" href="group___x_m_o_d_e_m128___exported___functions.html#ga09d8f1bd999f46b6c639fca0b651c08d">bXmodem128Stop</a>(<span class="keywordtype">void</span>);</div><div class="line"><a name="l00128"></a><span class="lineno">  128</span>&#160;<span class="preprocessor">#endif</span></div><div class="line"><a name="l00129"></a><span class="lineno">  129</span>&#160;</div><div class="line"><a name="l00130"></a><span class="lineno">  130</span>&#160;<span class="preprocessor">#ifdef __cplusplus</span></div><div class="line"><a name="l00131"></a><span class="lineno">  131</span>&#160;    }</div><div class="line"><a name="l00132"></a><span class="lineno">  132</span>&#160;<span class="preprocessor">#endif</span></div><div class="line"><a name="l00133"></a><span class="lineno">  133</span>&#160; </div><div class="line"><a name="l00134"></a><span class="lineno">  134</span>&#160;<span class="preprocessor">#endif  </span></div><div class="line"><a name="l00135"></a><span class="lineno">  135</span>&#160;</div><div class="line"><a name="l00136"></a><span class="lineno">  136</span>&#160;<span class="comment">/************************ Copyright (c) 2019 Bean *****END OF FILE****/</span></div><div class="line"><a name="l00137"></a><span class="lineno">  137</span>&#160;</div><div class="ttc" id="group___x_m_o_d_e_m128___exported___types_definitions_html_gad6ebbc53d3047463033cb2b686f40d66"><div class="ttname"><a href="group___x_m_o_d_e_m128___exported___types_definitions.html#gad6ebbc53d3047463033cb2b686f40d66">psend</a></div><div class="ttdeci">void(* psend)(uint8_t cmd)</div><div class="ttdef"><b>Definition:</b> <a href="b__xm128_8h_source.html#l00068">b_xm128.h:68</a></div></div>
<div class="ttc" id="group___x_m_o_d_e_m128___exported___functions_html_ga22d59aa816e006be041442488ea8539c"><div class="ttname"><a href="group___x_m_o_d_e_m128___exported___functions.html#ga22d59aa816e006be041442488ea8539c">bXmodem128Parse</a></div><div class="ttdeci">int bXmodem128Parse(uint8_t *pbuf, uint8_t len)</div></div>
<div class="ttc" id="group___x_m_o_d_e_m128___exported___functions_html_ga2999eae8ddb0eead2907b9e031e8f0cd"><div class="ttname"><a href="group___x_m_o_d_e_m128___exported___functions.html#ga2999eae8ddb0eead2907b9e031e8f0cd">bXmodem128Start</a></div><div class="ttdeci">int bXmodem128Start(void)</div></div>
<div class="ttc" id="structb_xmodem128_info__t_html_ad47d5b159b4c95a163edac9d1b659751"><div class="ttname"><a href="structb_xmodem128_info__t.html#ad47d5b159b4c95a163edac9d1b659751">bXmodem128Info_t::check</a></div><div class="ttdeci">uint8_t check</div><div class="ttdef"><b>Definition:</b> <a href="b__xm128_8h_source.html#l00063">b_xm128.h:63</a></div></div>
<div class="ttc" id="group___x_m_o_d_e_m128___exported___functions_html_ga09d8f1bd999f46b6c639fca0b651c08d"><div class="ttname"><a href="group___x_m_o_d_e_m128___exported___functions.html#ga09d8f1bd999f46b6c639fca0b651c08d">bXmodem128Stop</a></div><div class="ttdeci">int bXmodem128Stop(void)</div></div>
<div class="ttc" id="b__config_8h_html"><div class="ttname"><a href="b__config_8h.html">b_config.h</a></div></div>
<div class="ttc" id="structb_xmodem128_info__t_html_ae817be61f4d69f01a76ff417b23f5a54"><div class="ttname"><a href="structb_xmodem128_info__t.html#ae817be61f4d69f01a76ff417b23f5a54">bXmodem128Info_t::xnumber</a></div><div class="ttdeci">uint8_t xnumber</div><div class="ttdef"><b>Definition:</b> <a href="b__xm128_8h_source.html#l00061">b_xm128.h:61</a></div></div>
<div class="ttc" id="group___x_m_o_d_e_m128___exported___functions_html_ga75c122d0178d1616612a6d8e053ab3f4"><div class="ttname"><a href="group___x_m_o_d_e_m128___exported___functions.html#ga75c122d0178d1616612a6d8e053ab3f4">bXmodem128Init</a></div><div class="ttdeci">int bXmodem128Init(pcb_t fcb, psend fs)</div></div>
<div class="ttc" id="structb_xmodem128_info__t_html"><div class="ttname"><a href="structb_xmodem128_info__t.html">bXmodem128Info_t</a></div><div class="ttdef"><b>Definition:</b> <a href="b__xm128_8h_source.html#l00057">b_xm128.h:57</a></div></div>
<div class="ttc" id="group___x_m_o_d_e_m128___exported___types_definitions_html_ga1189ecafb71f5108788e9d2e7ac5e7f3"><div class="ttname"><a href="group___x_m_o_d_e_m128___exported___types_definitions.html#ga1189ecafb71f5108788e9d2e7ac5e7f3">pcb_t</a></div><div class="ttdeci">void(* pcb_t)(uint8_t number, uint8_t *pbuf)</div><div class="ttdef"><b>Definition:</b> <a href="b__xm128_8h_source.html#l00067">b_xm128.h:67</a></div></div>
<div class="ttc" id="structb_xmodem128_info__t_html_af57eaec6f3dec6de717735725c9908a6"><div class="ttname"><a href="structb_xmodem128_info__t.html#af57eaec6f3dec6de717735725c9908a6">bXmodem128Info_t::number</a></div><div class="ttdeci">uint8_t number</div><div class="ttdef"><b>Definition:</b> <a href="b__xm128_8h_source.html#l00060">b_xm128.h:60</a></div></div>
<div class="ttc" id="structb_xmodem128_info__t_html_a87bdcb2d9de9c3eef834e0af26f2d5e3"><div class="ttname"><a href="structb_xmodem128_info__t.html#a87bdcb2d9de9c3eef834e0af26f2d5e3">bXmodem128Info_t::soh</a></div><div class="ttdeci">uint8_t soh</div><div class="ttdef"><b>Definition:</b> <a href="b__xm128_8h_source.html#l00059">b_xm128.h:59</a></div></div>
</div><!-- fragment --></div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.8.14
</small></address>
</body>
</html>
